<?php
declare (strict_types = 1);

namespace app\api\controller;
use app\common\model\ClientModel;
use think\facade\Session;

class Client extends Common
{
    public function getList()
    {
        $admin_id = Session::get('admin_id');
        if(empty($admin_id)){
            return json(['code'=>1, 'msg'=>'请先登录','data'=>[]]);
        }
        
      $list = ClientModel::pageList();
      return json(['code'=>0,'msg'=>'success','data'=>$list]);
    }
}
